package main

import (
	"fmt"
	"strings"
)

func main() {
	fmt.Println(strStr("hello", "ll"))
}

func strStr(haystack string, needle string) int {
	for i := 0; i < len(haystack); i++ {
		if haystack[i] == needle[0] {
			if len(haystack[i:]) < len(needle) {
				return -1
			}
			v := haystack[i : i+len(needle)]
			if strings.EqualFold(v, needle) {
				return i
			}
		}

		continue
	}

	return -1
}


